﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace ReporterEngine
{
    public class ReportSettingsArgs
    {
        public string TemplatePath;
        public string ResultPath;
        public string ModelPath;
        public string ExportPath;

        public string ProjectName;
        public string TemplateName;
        public string ResultName;

        public int ReportPercentage = -1;

        public bool ReportFinished;

        public EventHandler ReportEnded;

        public Dictionary<string, string> Parameters = new Dictionary<string, string>();
        

        public List<MessageLogArgs> Messages = new List<MessageLogArgs>();

        //log, error messages
        public void AddMessageLog(MessageLogArgs args)
        {
            if(args.MessageLogType != MessageLogTypes.Debug)
                Messages.Add(args);

          //  if (OnAddMessageLog != null)
           //     OnAddMessageLog(args);
        }

        public void AddDebugMessageLog(string format, params object[] args)
        {
            if (false)
            {
                string result = string.Format(format, args);

                AddMessageLog(new MessageLogArgs {MessageLogType = MessageLogTypes.Debug, Message = result});
            }
        }
    }
}
